home *** CD-ROM | disk | FTP | other *** search
/ Celestin Apprentice 7 / Apprentice-Release7.iso / Source Code / C / Applications / MacPerl 5.1.3 / Mac_Perl_513_src / MacPerl5 / MPFile.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-12-17  |  1.9 KB  |  81 lines  |  [TEXT/MPS ]

  1. /*********************************************************************
  2. Project    :    MacPerl            -    Real Perl Application
  3. File        :    MPFile.h            -
  4. Author    :    Matthias Neeracher
  5.  
  6. A lot of this code is borrowed from 7Edit written by
  7. Apple Developer Support UK
  8.  
  9. Language    :    MPW C
  10.  
  11. $Log: MPFile.h,v $
  12. Revision 1.1  1994/02/27  23:03:17  neeri
  13. Initial revision
  14.  
  15. Revision 0.3  1993/08/29  00:00:00  neeri
  16. GetDocType
  17.  
  18. Revision 0.2  1993/08/13  00:00:00  neeri
  19. ApplySettings
  20.  
  21. Revision 0.1  1993/05/29  00:00:00  neeri
  22. Compiles correctly
  23.  
  24. *********************************************************************/
  25.  
  26. #ifndef __MPFILE__
  27. #define __MPFILE__
  28.  
  29. #include <Memory.h>
  30. #include <QuickDraw.h>
  31. #include <Traps.h>
  32. #include <Files.h>
  33. #include <Packages.h>
  34. #ifdef EVIL_USELESS_EDITIONS
  35. #include <Editions.h>
  36. #endif
  37. #include <AppleEvents.h>
  38. #include <Printing.h>
  39.  
  40. #include "MPGlobals.h"
  41. #include "MPUtils.h"
  42. #include "MPWindow.h"
  43. #include "MPEditions.h"
  44.  
  45. pascal void DoQuit(DescType saveOpt);
  46.  
  47. pascal OSErr DoClose(WindowPtr aWindow, Boolean canInteract, DescType dialogAnswer);
  48.  
  49. pascal OSErr GetFileNameToSaveAs(DPtr theDocument);
  50.  
  51. pascal OSErr GetFileContents(FSSpec theFSSpec, DPtr theDocument);
  52.  
  53. pascal void FileError(Str255 s, Str255 f);
  54.  
  55. pascal OSErr SaveAskingName(DPtr theDocument, Boolean canInteract);
  56.  
  57. pascal OSErr SaveUsingTemp(DPtr theDocument);
  58.  
  59. pascal OSErr SaveWithoutTemp(DPtr theDocument, FSSpec spec);
  60.  
  61. pascal OSErr DoCreate(FSSpec theSpec);
  62.  
  63. pascal OSErr OpenOld(FSSpec aFSSpec, DocType type);
  64.  
  65. pascal OSErr GetFile(FSSpec *theFSSpec);
  66.  
  67. pascal void ApplySettings(DPtr doc, HPtr settings);
  68.  
  69. pascal OSErr SaveConsole(DPtr doc);
  70.  
  71. pascal void RestoreConsole(DPtr doc);
  72.  
  73. pascal OSErr Handle2File(Handle text, FSSpec toFSSpec, DocType newtype);
  74.  
  75. pascal OSErr File2File(FSSpec aFSSpec, DocType type, FSSpec toFSSpec, DocType newtype);
  76.  
  77. pascal DocType GetDocType(FSSpec * spec);
  78.  
  79. pascal DocType GetDocTypeFromInfo(CInfoPBPtr info);
  80.  
  81. #endif